<template>
	<div>
		<top-nav bgColor="white" title="批量下单"  btnName="btn"  :rightShow="false" returnPath="factoryList"></top-nav>
		
		<div style="width: 100%;height: 3rem;"></div>
		<section @click='checkbox'>
		<!--<mu-checkbox label="所有订单" class="demo-checkbox"  v-model='checkdshowclose' @click="checkbox" />-->
		 <el-checkbox v-model="checkdshowclose"  @click='checkbox' >所有订单</el-checkbox>
		</section>
		<order-card-item v-for="item in list"
			:ID="item.ID"
			:BillNo="item.BillNo"
			:CustomName="item.CustomName"
			:Balance="item.Balance"
			:CustomID="item.CustomID"
			:CustomNumber="item.CustomNumber"
			:Time="item.Time"
			:item="item"
/>
	</div>
</template>

<script>
	 import TopNav from '@/components/nav/topNav.vue'
	 import OrderCardItem from '@/page/project/jinxitai/menuChild/addGrantBills/orderCardItem.vue'
	 export default {
		components: {
		      TopNav,
		      OrderCardItem
		},
		data(){
			return{
				list:[],
				checkdshowclose:true
			}
		},
		mounted(){
			console.info(this.list)
			this.getAppOrderList()
			
			
		},
		methods:{
//			getAllOrder(){
//				let that=this
//				that.axios.post('/demo/getAllOrder',{
//					'factoryId':this.$parent.factoryId,
//					'uid':localStorage.uid,
//					'currentpage':1
//				}).then(function(response){
//					that.list=response.data.data.list
//					console.info(response.data.data)
//				}).catch(function(error){
//					
//				})
			getAppOrderList(){
				let that=this
				let showclose=1
				if(that.checkdshowclose){
				showclose=0
				}
				that.axios.post('/jinxitai/getAppOrderList',{
					'factoryId':localStorage.factoryId,
					'uid':localStorage.uid,
					'showclose':showclose
				}).then(function(response){
					console.info(response.data.data)
					that.list=response.data.data.list
				}).catch(function(error){
					
				})
			},
			checkbox()
			{
				this.getAppOrderList()
			}
	 		}
	}
</script>

<style>
</style>